// interface 接口名称 {
//   属性名称:属性类型;
//   方法名称():返回值类型;
// }
interface Student {
    name: string;
    age: number;
    sex?: string; // 可选属性
    readonly className: string; // 只读属性, 不能被修改,类似于常量
}

let zs: Student = {
    name: "张三",
    age: 18,
    className: "1班"
}
let ls: Student = {
    name: "李四",
    age: 18,
    sex: "男",
    className: "1班"
}
// zs.className = "2班"
